#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>

int main(){
	char ch;
	int lat, bla, dig, oth;
	lat = bla = dig = oth = 0;
	for (int i = 1; i <= 10; i++){
		ch = getchar();

		if ((ch >= 'a'&&ch <= 'z') || (ch >= 'A'&&ch <= 'Z')){
			lat++;
		}
		else if (ch == ' ' || ch == '\n'){
			bla++;
		}
		else if (ch >= '0'&&ch <= '9'){
			dig++;
		}
		else{
			oth++;
		}
	}
	printf("letter = %d, blank = %d, digit = %d, other = %d", lat, bla, dig, oth);
	return 0;
}